public enum OperEnum {

    ADD(1,6){//加法
        @Override
        public Integer operate() {
            return getA()+getB();
        }
    },MULTIPLICATION(5,9){//乘法
        @Override
        public Integer operate() {
            return getA()*getB();
        }
    };

    OperEnum(int a, int b) {
        this.a = a;
        this.b = b;
    }

    private int a;

    private int b;

    public int getA() {
        return a;
    }

    public void setA(int a) {
        this.a = a;
    }

    public int getB() {
        return b;
    }

    public void setB(int b) {
        this.b = b;
    }

    public abstract Integer operate();


    public static void main(String[] args) {
        System.out.println(OperEnum.ADD);
    }

}
